import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import 'lib-flexible'
import './assets/fonts/iconfont.css'
import {
  Field,
  Form,
  SidebarItem,
  Sidebar,
  Search,
  DropdownMenu,
  DropdownItem,
  Stepper,
  Popup,
  Tag,
  Icon,
  Tabbar,
  TabbarItem,
  Swipe,
  SwipeItem,
  Grid,
  GridItem,
  Card,
  Button,
  PullRefresh,
  List,
  NavBar,
  GoodsAction,
  GoodsActionIcon,
  GoodsActionButton,
  Empty,
  SubmitBar,
  Checkbox,
  Toast,
  SwipeCell,
  ContactCard,
  AddressList,
  Area,
  Cell,
  CellGroup,
  Switch,
  Lazyload,
  Dialog
} from 'vant'
import loading from '@/plugins/loading'
Vue.use(loading)
Vue.use(Icon)
  .use(Tabbar)
  .use(TabbarItem)
  .use(Swipe)
  .use(SwipeItem)
  .use(Grid)
  .use(GridItem)
  .use(Card)
  .use(Button)
  .use(Tag)
  .use(PullRefresh)
  .use(List)
  .use(NavBar)
  .use(GoodsAction)
  .use(GoodsActionIcon)
  .use(GoodsActionButton)
  .use(Popup)
  .use(Stepper)
  .use(DropdownMenu)
  .use(DropdownItem)
  .use(Search)
  .use(Sidebar)
  .use(SidebarItem)
  .use(Form)
  .use(Field)
  .use(Empty)
  .use(SubmitBar)
  .use(Checkbox)
  .use(Toast)
  .use(SwipeCell)
  .use(ContactCard)
  .use(AddressList)
  .use(Area)
  .use(Cell)
  .use(CellGroup)
  .use(Switch)
  .use(Dialog)
  .use(Lazyload, {
    loading: require('./assets/img/dagu.jpg'),
    error: require('./assets/img/pual wwalker GTR.jpg'),
    preload: 1,
    attempt: 3
  })

Vue.config.productionTip = false
Vue.prototype.$dialog = Dialog
new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
